import React from 'react';
import { inject, observer } from 'mobx-react';
import {WeaErrorPage,WeaTools,WeaDialog} from 'ecCom'
import { Button } from 'antd';

import AddSubComs from './AddSubComs';


@inject('wfCusReportAddStore')

@observer
class CustomReportsAdd extends React.Component {
    constructor(props){
        super(props);
        this.state={
        }
    }
    render(){
        const { wfCusReportAddStore } = this.props;
        const { ReportsBtns , setCusReportAddModalShow , customReportAddModalShow} = wfCusReportAddStore;
        return(<div style={{height:"100%"}}>
                <Button ecId={`${this && this.props && this.props.ecId || ''}_Button@i393gh`} type="primary" onClick={()=>{setCusReportAddModalShow(true)}}>
                    新建
                </Button>
                <Button ecId={`${this && this.props && this.props.ecId || ''}_Button@mkozi3`} type="primary" onClick={()=>{setCusReportAddModalShow(true,386)}}>
                    编辑
                </Button>
                <AddSubComs ecId={`${this && this.props && this.props.ecId || ''}_AddSubComs@4iss60`}/>
            </div>)
    }
   
   
}

export default WeaTools.tryCatch(React,
    props => <WeaErrorPage ecId={`${this && this.props && this.props.ecId || ''}_WeaErrorPage@bpbe18`} msg={ props.error ? props.error : '对不起，该页面异常，请联系管理员！'} />,
    {error: ""}
    )(CustomReportsAdd);